<template>
	<view>
		<view class="status_bar" style="height: var(--status-bar-height); width: 100%;"></view>
		<navbar left-text="返回" titleText="空框出库" />
		<rform />
	</view>
</template>

<script>
	import tabbar from '@/components/tabbar.vue'
	import navbar from '@/components/navbar.vue'
	import Rform from './/components/rf-form.vue'
	export default {
		data() {
			return {
				LPN:'',
				formData: {
					wuliao: ''
				},
				swiperHeight: ''
			};
		},
		components: {
			tabbar,
			navbar,
			Rform
		},
		onLoad(args) {
		    //动态设置swiper的高度
		    this.$nextTick(() => {
		      this.setSwiperHeight();
		    });
		  },
		methods: {
			scanClick(e) {
				console.log(e)
				uni.scanCode({
					success: function (res) {
						console.log('条码类型：' + res.scanType);
						console.log('条码内容：' + res.result);
					}
				});
			},
			//动态设置swiper的高度
			setSwiperHeight() {
				let query = uni.createSelectorQuery().in(this);
				query.select('.form-swiper').boundingClientRect();
				query.exec((res) => {
					if (res && res[0]) {
						this.swiperHeight = res[0].height;
					}
				});
			},
		}
	}
</script>

<style lang="scss">

</style>
